import request from '@/utils/request'

// 查询客户门店列表
export function listCustomerStore(query) {
  return request({
    url: '/vanger/customerStore/list',
    method: 'get',
    params: query
  })
}

// 查询客户门店列表（联合）
export function listUnion(query) {
  return request({
    url: '/vanger/customerStore/listUnion',
    method: 'get',
    params: query
  })
}


// 查询客户门店详细（联合）
export function getInfoUnion(id) {
  return request({
    url: '/vanger/customerStore/getInfoUnion/' + id,
    method: 'get'
  })
}

// 查询客户门店详细
export function getCustomerStore(id) {
  return request({
    url: '/vanger/customerStore/' + id,
    method: 'get'
  })
}

// 新增客户门店
export function addCustomerStore(data) {
  return request({
    url: '/vanger/customerStore',
    method: 'post',
    data: data
  })
}

// 修改客户门店
export function updateCustomerStore(data) {
  return request({
    url: '/vanger/customerStore',
    method: 'put',
    data: data
  })
}

// 删除客户门店
export function delCustomerStore(id) {
  return request({
    url: '/vanger/customerStore/' + id,
    method: 'delete'
  })
}
